import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { ProfitRatioVO, ProfitRatioForm, ProfitRatioQuery } from '@/api/retail/profitRatio/types';

/**
 * 查询商店收益比率列表
 * @param loginName
 */
export const listProfitRatio = (loginName?: string | string[]): AxiosPromise<any> => {
  const data = {
    loginName: loginName
  };
  return request({
    url: '/retail/profitRatio/list',
    method: 'get',
    params: data
  });
};

/**
 * 新增商店收益比率
 * @param data
 */
export const saveProfitRatio = (data: any) => {
  return request({
    url: '/retail/profitRatio/save',
    method: 'post',
    data: data
  });
};
